import request from '@/utils/request';

// 下载模板
export function downloadTemp(params) {
  return request({
    url: '/downloadTemp',
    method: 'get',
    responseType: 'arraybuffer',
    params: params
  })
}

// 上传值班记录
export function uploadRecord(data) {
  return request({
    url: '/uploadRecord',
    method: 'post',
    data: data
  })
}

// 查询值班列表
export function queryDutyList(params) {
  return request({
    url: '/queryDutyList',
    method: 'get',
    params: params
  })
}

// 删除值班
export function deleteDuty(params) {
  return request({
    url: '/deleteDuty',
    method: 'get',
    params: params
  })
}

// 下载值班表
export function downloadDuty(params) {
  return request({
    url: '/downloadDuty',
    method: 'get',
    responseType: 'arraybuffer',
    params: params
  })
}

// 查看
export function viewDuty(params) {
  return request({
    url: '/viewDuty',
    method: 'get',
    params: params
  })
}